//2:定义一个整数数组，判断是否是递增有序的，即数组中的每一个数，都不大于其后面的数，比如{1,3,6｝，{1,2,2,4,6,9,9}等
package ZUOYE0424;

import java.util.Scanner;

public class Task2 {

	public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int num[] = new int[10];
		System.out.println("输入十个数：");
		for (int a = 0; a < num.length; a++) {
			num[a] = in.nextInt();
		}
		boolean q = true;
		for (int b = 0; b < num.length - 1; b++) {
			if (num[b] > num[b + 1]) {
				q = false;
				break;
			}
		}
		if (q == true) {
			System.out.println("该数组是递增有序的");
		} else {
			System.out.println("该数组不是递增有序的");
		}
	}

}
